<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>接待申请单打印</title>
    <#include "/common/resource.ftl">
    <style>
        body{background:#eee}
        .print-container{width:210mm;margin: 0 auto;}
        .print-container .layui-card-body{min-height:297mm;padding1:25.4mm 32.8mm;}
        .header{font-size:28px;text-align:center;margin:30px 0px;}
        .content{padding-left:40px;min-height:50px;}
        .footer{text-align:right;padding-right:150px;}
        .layui-table td{border:1px solid #000;}
        .layui-table td, .layui-table td *{font-size:18px;line-height:30px;color:#000;}
        @media print{
            .print-container .layui-card-header{display:none;}
        }
    </style>
</head>
<body>
<div class="layui-card print-container">
    <div class="layui-card-header">接待申请单
        <button type="button" class="layui-btn" style="float:right;margin-top:8px;" onclick='javascript:window.print();'>打印</button>
    </div>
    <div class="layui-card-body">
        <div class="header">接待申请单</div>
        <table class="layui-table">
            <tbody>
                <tr>
                    <td style="width:100px;">申请人：</td>
                    <td field="createName"></td>
                    <td style="width:100px;">负责人：</td>
                    <td field="chargeUser"></td>
                </tr>
                <tr>
                    <td style="width:100px;">接待时间：</td>
                    <td field="receiveTimeStr"></td>
                    <td style="width:100px;">类别：</td>
                    <td field="categoryStr"></td>
                </tr>
                <tr>
                    <td style="width:100px;">接待费用：</td>
                    <td field="cost"></td>
                    <td style="width:100px;">费用归属：</td>
                    <td field="costOwner"></td>
                </tr>
                <tr>
                    <td colspan="4">
                        <div>行程安排：</div>
                        <div class="content" field="schedule"></div>
                    </td>
                </tr>
                <tr>
                    <td colspan="4">
                        <div>接待要求：</div>
                        <div class="content" field="require"></div>
                    </td>
                </tr>
                <tr>
                    <td colspan="4">
                        <div>行政部审批意见：</div>
                        <div class="content" field="advert_extend_valid"></div>
                        <div class="footer">签字：</div>
                        <div class="footer">日期：</div>
                    </td>
                </tr>
                <tr>
                    <td colspan="4">
                        <div>院长审批意见：</div>
                        <div class="content" field="advert_project_valid"></div>
                        <div class="footer">签字：</div>
                        <div class="footer">日期：</div>
                    </td>
                </tr>
                <tr>
                    <td colspan="4">
                        <div>备注：</div>
                        <div class="content" field="remark"></div>
                    </td>
                </tr>
            </tbody>
        </table>
    </div>
</div>
<script type="text/javascript">
    $(function () {
        <#if (params.id)??>
        $.ajaxRequest({
            url: '${params.contextPath}/web/receiveApply/query',
            data: {id: "${params.id!}"},
            success: function (data) {
                if (!data.success) {
                    $.message(data.message);
                    return;
                }
                var record = data.data;
                for (var key in record) {
                    $("[field='" + key + "']").html(record[key]);
                }
            }
        });
        </#if>
    });
</script>
</body>

</html>
